<template>
  <van-dialog
    v-model="activationVisible"
    title="激活码"
    show-cancel-button
    @close="closeVisble"
  >
    <van-field v-model="codeText" autofocus placeholder="请输入激活码" />
  </van-dialog>
</template>

<script>
import Vue from "vue";
import { Dialog, Field } from "vant";
Vue.use(Dialog);
Vue.use(Field);

export default {
  name: "Authority",
  props: {},
  data() {
    return {
      codeText: "",
    };
  },
  computed: {
    activationVisible: {
      get() {
        return this.$store.state.activationVisible;
      },
      set() {
        this.closeVisble();
      },
    },
  },
  methods: {
    closeVisble() {
      this.$store.commit("SET_TOTLE_DATA", {
        activationVisible: false,
      });
    },
  },
};
</script>
<style lang="scss" scoped>
</style>
